import request from '@/utils/request'
//获取门类和全宗
export function gettrees(query) {
    return request({
      url: '/archive/archiveRelease/gettrees',
      method: 'GET',
      params: query
    })
  }
//获取利用平台的全宗以及门类
export function getArchiveTree(query) {
  return request({
    url: '/archive/archiveRelease/getArchiveTree',
    method: 'GET',
    params: query
  })
}
//获取元数据
export function getMetadata(query) {
  return request({
    url: '/archive/archiveRelease/getMetadata',
    method: 'GET',
    params: query
  })
}

//新增方案
export function archiveRelease(data) {
  return request({
    url: '/archive/archiveRelease',
    method: 'POST',
    data: data
  })
}

//修改方案
export function archiveReleaseDeit(data) {
  return request({
    url: '/archive/archiveRelease',
    method: 'PUT',
    data: data
  })
}

//发布列表 
export function listexportList(query) {
  return request({
    url: '/archive/archiveRelease/list',
    method: 'GET',
    params: query
  })
}

//配置接口
export function allocation(data) {
  return request({
    url: '/archive/archiveRelease/allocation',
    method: 'PUT',
    data: data
  })
}
//方案详情
export function allocationDelit(Id) {
  return request({
    url: '/archive/archiveRelease/'+Id,
    method: 'GET',
  })
}

//方案删除
export function archiveReleaseDel(ids) {
  return request({
    url: '/archive/archiveRelease/'+ids,
    method: 'DELETE',
  })
}


//发布日志列表
export function releaseLogList(query) {
  return request({
    url: '/archive/releaseLog/list',
    method: 'GET',
    params: query
  })
}
//删除日志
export function releaseLog(ids) {
  return request({
    url: '/archive/releaseLog/'+ids,
    method: 'DELETE',
  })
}
//发布
export function releasefb(id) {
  return request({
    url: '/archive/archiveRelease/release?id='+id,
    method: 'GET',
  })
}
